<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<!-- 开发环境版本，包含了有帮助的命令行警告 -->
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<title></title>
<div id="app">
	<h1>{{count}}</h1>
	<button @click="hello" value=1>1</button>
	<button @click="hello" value=2>2</button>
	<button @click="hello" value=3>3</button>
	<button @click="hello" value=4>4</button>
	<button @click="hello" value=5>5</button>
</div>


</head>
<body>
	<script>
		new Vue({
			el:"#app",
			data:{
				count:0
			},
			methods:{
				hello:function(event){
					this.count+=Number(event.target.value)
					
				}
			
				/*	this.count +=1
				},
				    this.count =2
				},
				this.count =3
				},
				this.count =4
				},
				this.count =5
				}
			}*/
			}
		})
	</script>
</body>
</html>
